home *** CD-ROM | disk | FTP | other *** search
/ The 640 MEG Shareware Studio 2 / The 640 Meg Shareware Studio CD-ROM Volume II (Data Express)(1993).ISO / pascal / boost4.zip / SUBWORD.PAS < prev    next >
Pascal/Delphi Source File  |  1988-10-23  |  577b  |  29 lines

  1. program sword;
  2.  
  3. { Exercises in using Boosters' word functions }
  4.  
  5. uses BOSHARE,crt;
  6. var s : string;
  7.     i : integer;
  8.  
  9. begin
  10.  
  11.    Writeln('Finding string subsets using Boosters'' Subword');
  12.    Writeln;
  13.    s := '   1 2 3 4 5 6';
  14.    writeln(s);
  15.    for i := 0 to 7 do begin
  16.       writeln( subword(s,i,6) );
  17.       writeln( wordind(s,5) );
  18.       readln;
  19.    end;
  20.  
  21.    s := 'These are the good old days . . .';
  22.    writeln(s);
  23.    for i := 1 to words(s) do begin
  24.       writeln( subword(s,i,words(s)) );
  25.       writeln( wordind(s,i) );
  26.       readln;
  27.    end;
  28.  
  29. end.